<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the Closure to execute when that URI is requested.
|
*/
    
    // <editor-fold defaultstate="collapsed" desc="Routes For Login">
        
    Route::get('/', array('as' => 'index','uses' => 'LoginController@index'));
    Route::get('/login', array('as' => 'login','uses' => 'LoginController@showLogin'));
    Route::post('/login', array('as' => 'loginPOST','uses' => 'LoginController@doLogin'));
    Route::get('/logout', array('as' => 'logout','uses' => 'LoginController@doLogout'));
    Route::get('/forbidden', array('as' => 'login','uses' => 'LoginController@showForbidden'));
    
    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For Home">
    
    Route::get('/home', array('uses' => 'HomeController@index'));
    Route::get('/admin', array('uses' => 'HomeController@admin'));
    Route::get('/leader', array('uses' => 'HomeController@leader'));
    Route::get('/employee', array('uses' => 'HomeController@employee'));
    Route::get('/blank', array('uses' => 'HomeController@blank'));

    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For User">

    Route::get('/user', array('uses' => 'UserController@index'));
    Route::get('/user/detail/{id?}' ,array('uses' => 'UserController@detail'));
    Route::get('/user/delete/{id?}' ,array('uses' => 'UserController@delete'));
    Route::get('/user/create' ,array('uses' => 'UserController@create'));
    Route::post('/user/create' ,array('uses' => 'UserController@create'));
    Route::get('/user/edit/{id?}' ,array('uses' => 'UserController@edit'));
    Route::post('/user/edit/{id?}' ,array('uses' => 'UserController@edit'));
    
    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For UserGroup">

    Route::get('/usergroup', array('uses' => 'UserGroupController@index'));
    Route::get('/usergroup/detail/{id?}' ,array('uses' => 'UserGroupController@detail'));
    Route::get('/usergroup/delete/{id?}' ,array('uses' => 'UserGroupController@delete'));
    Route::get('/usergroup/create' ,array('uses' => 'UserGroupController@create'));
    Route::post('/usergroup/create' ,array('uses' => 'UserGroupController@create'));
    Route::get('/usergroup/edit/{id?}' ,array('uses' => 'UserGroupController@edit'));
    Route::post('/usergroup/edit/{id?}' ,array('uses' => 'UserGroupController@edit'));
    
    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For Function">

    Route::get('/functions', array('uses' => 'FunctionsController@index'));
    Route::get('/functions/detail/{id?}' ,array('uses' => 'FunctionsController@detail'));
    Route::get('/functions/delete/{id?}' ,array('uses' => 'FunctionsController@delete'));
    Route::get('/functions/create' ,array('uses' => 'FunctionsController@create'));
    Route::post('/functions/create' ,array('uses' => 'FunctionsController@create'));
    Route::get('/functions/edit/{id?}' ,array('uses' => 'FunctionsController@edit'));
    Route::post('/functions/edit/{id?}' ,array('uses' => 'FunctionsController@edit'));

    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For Module">

    Route::get('/module', array('uses' => 'ModuleController@index'));
    Route::get('/module/detail/{id?}' ,array('uses' => 'ModuleController@detail'));
    Route::get('/module/delete/{id?}' ,array('uses' => 'ModuleController@delete'));
    Route::get('/module/create' ,array('uses' => 'ModuleController@create'));
    Route::post('/module/create' ,array('uses' => 'ModuleController@create'));
    Route::get('/module/edit/{id?}' ,array('uses' => 'ModuleController@edit'));
    Route::post('/module/edit/{id?}' ,array('uses' => 'ModuleController@edit'));

    // </editor-fold>

    // <editor-fold defaultstate="collapsed" desc="Routes For Project">

    Route::get('/project', array('uses' => 'ProjectController@index'));
    Route::get('/project/detail/{id?}' ,array('uses' => 'ProjectController@detail'));
    Route::get('/project/delete/{id?}' ,array('uses' => 'ProjectController@delete'));
    Route::get('/project/create' ,array('uses' => 'ProjectController@create'));
    Route::post('/project/create' ,array('uses' => 'ProjectController@create'));
    Route::get('/project/edit/{id?}' ,array('uses' => 'ProjectController@edit'));
    Route::post('/project/edit/{id?}' ,array('uses' => 'ProjectController@edit'));

    // </editor-fold>
	
    // <editor-fold defaultstate="collapsed" desc="Routes For Task">
    
    Route::get('/task', array('uses' => 'TaskController@index'));
    Route::get('/task/detail/{id?}' ,array('uses' => 'TaskController@detail'));
    Route::post('/task/detail/{id?}' ,array('uses' => 'TaskController@detail'));
    Route::get('/task/delete/{id?}' ,array('uses' => 'TaskController@delete'));
    Route::get('/task/create' ,array('uses' => 'TaskController@create'));
    Route::post('/task/create' ,array('uses' => 'TaskController@create'));
    Route::get('/task/edit/{id?}' ,array('uses' => 'TaskController@edit'));
    Route::post('/task/edit/{id?}' ,array('uses' => 'TaskController@edit'));
    Route::get('/task/assignTask/{id?}' ,array('uses' => 'TaskController@assignTask'));
    Route::get('/task/done/{id?}' ,array('uses' => 'TaskController@done'));
    Route::post('/task/assignTask/{id?}' ,array('uses' => 'TaskController@assignTask'));

    // </editor-fold>
    
    // <editor-fold defaultstate="collapsed" desc="Routes For Issue">
    
    Route::get('/issue', array('uses' => 'IssueController@index'));
    Route::get('/issue/detail/{id?}' ,array('uses' => 'IssueController@detail'));
    Route::post('/issue/detail/{id?}' ,array('uses' => 'IssueController@detail'));
    Route::get('/issue/delete/{id?}' ,array('uses' => 'IssueController@delete'));
    Route::get('/issue/create' ,array('uses' => 'IssueController@create'));
    Route::post('/issue/create' ,array('uses' => 'IssueController@create'));
    Route::get('/issue/edit/{id?}' ,array('uses' => 'IssueController@edit'));
    Route::get('/issue/done/{id?}' ,array('uses' => 'IssueController@done'));
    Route::post('/issue/edit/{id?}' ,array('uses' => 'IssueController@edit'));
    
    // </editor-fold>
    
    // <editor-fold defaultstate="collapsed" desc="Routes For Priority">
    
    Route::get('/priority', array('uses' => 'PriorityController@index'));
    Route::get('/priority/detail/{id?}' ,array('uses' => 'PriorityController@detail'));
    Route::get('/priority/delete/{id?}' ,array('uses' => 'PriorityController@delete'));
    Route::get('/priority/create' ,array('uses' => 'PriorityController@create'));
    Route::post('/priority/create' ,array('uses' => 'PriorityController@create'));
    Route::get('/priority/edit/{id?}' ,array('uses' => 'PriorityController@edit'));
    Route::post('/priority/edit/{id?}' ,array('uses' => 'PriorityController@edit'));

    // </editor-fold>
    
    // <editor-fold defaultstate="collapsed" desc="Routes For Log">

    Route::get('/log', array('uses' => 'LogController@index'));
    Route::get('/log/detail/{id?}' ,array('uses' => 'LogController@detail'));
    Route::get('/log/create' ,array('uses' => 'LogController@create'));
    Route::post('/log/create' ,array('uses' => 'LogController@create'));

    // </editor-fold>
    
    // <editor-fold defaultstate="collapsed" desc="Routes For Status">

    Route::get('/status', array('uses' => 'StatusController@index'));
    Route::get('/status/detail/{id?}' ,array('uses' => 'StatusController@detail'));
    Route::get('/status/delete/{id?}' ,array('uses' => 'StatusController@delete'));
    Route::get('/status/create' ,array('uses' => 'StatusController@create'));
    Route::post('/status/create' ,array('uses' => 'StatusController@create'));
    Route::get('/status/edit/{id?}' ,array('uses' => 'StatusController@edit'));
    Route::post('/status/edit/{id?}' ,array('uses' => 'StatusController@edit'));

    // </editor-fold>
    